﻿//----------------------------------------------------------------
// Copyright (C) 2011-2012 TaoSys软件有限责任公司
// All rights reserved.
//
// 文件名：XException.cs
// 摘  要：异常基类
// 说  明：
//

//当前版本：1.0
//作    者：陶剑扬
//完成日期：2011-07-03
//----------------------------------------------------------------

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Runtime.Serialization;

namespace PowerSys.SystemFramework.ExceptionManagment
{
    public class XException : ApplicationException
    {
        public Exception SystemException { get; set; }
        public bool IsRecord { get; set; }

        public XException():base()
        {
            IsRecord = false;
        }

        public XException(string message)
            : base(message)
        {
            IsRecord = false;
        }

        public XException(string message, bool isRecord)
            : base(message)
        {
            IsRecord = isRecord;
        }


        public XException(string message, Exception innerException)
            : base(message, innerException)
        {
            IsRecord = false;
        }

        public XException(SerializationInfo info, StreamingContext context)
            : base(info, context)
        {
        }

        public XException(string message, Exception innerException, bool isRecord)
            : base(message, innerException)
        {
            IsRecord = isRecord;
        }
    }
}
